﻿using LoongCAD.STC.Friendly.Dialog.UIControls;
using LoongCAD.STC.Friendly.Plugins;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConnectionDemo
{
    /// <summary>
    /// 组件窗口参数
    /// 需要将所有字段初始化作为对应的默认值
    /// </summary>
    [AttributeFields]
    public class StructuresData
    {

        public BoltBasicPropertyPanel.Data boltBasicProps = new BoltBasicPropertyPanel.Data();

        public BoltHolePanel.Data boltHoleProps = new BoltHolePanel.Data();

        public BoltContentPanel.Data boltContentProps = new BoltContentPanel.Data();

        public BoltExtendPanel.Data boltExtendProps = new BoltExtendPanel.Data();

        public PlatePropertyPanel.Data plateProps = new PlatePropertyPanel.Data();

        public double beamDist = 10.0;

        public double platePos = double.MaxValue;

        public double boltMarginT = 50.0;

        public int boltVertCount = 2;

        public double boltVertDist = 70.0;

        public int boltHoriCount = 2;

        public double boltHoriDist = 70.0;

        public double boltMarginL = 50.0;

        public double boltMarginR = 50.0;


        public StructuresData()
        {
            plateProps.Thickness = 10;
            plateProps.Material = "Q235B";
            plateProps.NoPrefix = "B";
            plateProps.Name = "板";

            boltBasicProps.BoltStandard = "HS10.9";
            boltBasicProps.BoltSize = 24.0;
            boltBasicProps.HoleTol = 2.0;

            boltHoleProps.HoleX = 0.0;
            boltHoleProps.HoleY = 0.0;
            boltHoleProps.HoleType = 0;
            boltHoleProps.RotSlot = 0;
            boltHoleProps.SlotIn = 0;

            boltContentProps.WasherUp = true;
            boltContentProps.WasherDown0 = true;
            boltContentProps.WasherDown1 = false;
            boltContentProps.Nut0 = true;
            boltContentProps.Nut1 = false;

            boltExtendProps.ExtLength = 2.0;
        }
    }

}
